function calculate() {
  let g = 9.8
  let input1 = parseFloat(document.getElementById("input1").value);   //φ1
  let input2 = parseFloat(document.getElementById("input2").value);   //φ2
  let input3 = parseFloat(document.getElementById("input3").value);  //k1
  let input4 = parseFloat(document.getElementById("input4").value);  //k2
  let input5 = parseFloat(document.getElementById("input5").value);   //s1
  let input6 = parseFloat(document.getElementById("input6").value);   //s2
  let input7 = parseFloat(document.getElementById("input7").value);  //m1
  let input8 = parseFloat(document.getElementById("input8").value);  //m2  
  let input9 = parseFloat(document.getElementById("input9").value);  //α
  let input10 = parseFloat(document.getElementById("input10").value);  //β



  if (!input1 ) input1  = 0;
  if (!input2 ) input2  = 0;
  if (!input3 ) input3  = 0;  
  if (!input4 ) input1  = 0;
  if (!input5 ) input2  = 0;
  if (!input6 ) input3  = 0;
  if (!input7 ) input1  = 0;
  if (!input8 ) input2  = 0;  
  if (!input9 ) input1  = 0;
  if (!input10 ) input2  = 0;

  console.log("input1=",input1)
  console.log("input2=",input2)

  //v1的结果
  let result = (Math.sqrt(2*g*input1*input3*input5)*Math.cos(input9)+input8/input7*Math.sqrt(2*g*input2*input4*input6)*Math.sin(input10))*3.6;
 //v2的结果
  let result1 = (input7/input8*Math.sqrt(2*input1*g*input3*input5)*Math.sin(input9)+Math.sqrt(2*input2*g*input4*input6)*Math.cos(input10))*3.6


  if (result == 'NaN') {
    result = 0
    alert('请按要求输入数据！')
    location.reload()
  }
  //v1的结果
  document.getElementById("result").textContent = result.toFixed(2);
   //v2的结果
  document.getElementById("result1").textContent = result1.toFixed(2);

}